/*
 * Eugen Stoian <stoian.e@gmail.com> 2010
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 */

#ifndef SURFACE3D_H
#define SURFACE3D_H
#include <QMap>
#include <ParametricObject3D.h>

class Expression3D;
class Curve3D;

class Surface3D : public ParametricObject3D
{
    Q_OBJECT
public:
    Surface3D(QObject *parent = 0);

    Surface3D(const Expression3D* expr, QObject *parent = 0);

    Surface3D(const QString& expressionName, QObject *parent = 0);

    virtual void draw();

    virtual bool isValid() const;

    virtual int type() const;

    virtual bool isEmpty() const;

    virtual Object* clone() const;

    const QMap<double, Curve3D* >& uLines() const;

    const QMap<double, Curve3D* >& vLines() const;

    int count() const;

public slots:
    virtual void compute();

protected:
    virtual void cleanUpPoints();

    virtual void cleanUp();
private:
    QMap<double, Curve3D* > _uLines;
    QMap<double, Curve3D* > _vLines;
};

#endif // SURFACE3D_H
